/**
   @file sys_usw_scl.h

   @date 2017-01-23

   @version v1.0

   The file contains all acl APIs of sys layer

 */
 #ifndef _SYS_USW_ACL_API_H
#define _SYS_USW_ACL_API_H

#ifdef __cplusplus
extern "C" {
#endif
/****************************************************************************
*
* Header Files
*
****************************************************************************/
#include "sal.h"
#include "ctc_common.h"
#include "ctc_acl.h"
#include "ctc_field.h"
#include "sys_usw_common.h"
#include "ctc_linklist.h"


/****************************************************************************
 *
 * Defines and Macros
 *
 *****************************************************************************/

#define SYS_ACL_USW_GROUP_HASH_SIZE            1024
#define SYS_ACL_USW_ENTRY_HASH_SIZE            ( (SYS_FTM_SPEC(lchip, CTC_FTM_SPEC_ACL_FLOW)/SYS_HASH_SIZE_COMPRESS_RATE_8) + \
                                                 (SYS_FTM_SPEC(lchip, CTC_FTM_SPEC_ACL)/SYS_HASH_SIZE_COMPRESS_RATE_2) )
#define ACL_IGS_BLK_MAX_NUM    24      /* ingress acl */
#define ACL_EGS_BLK_MAX_NUM    12      /* egress acl */
#define ACL_HASH_MAX_NUM       3

#define SYS_ACL_HASH_SEL_PROFILE_MAX    16
#define SYS_ACL_MAX_UDF_ENTRY_NUM       512
#define SYS_ACL_PRESEL_ID_MAX           582     /* Maximum Preselection entries supported. [AT] TCAM:24*16+12*16; XFLOW: 7 */

#define SYS_ACL_NPM_IM_FLOW_ID           32
#define SYS_ACL_NPM_IM_BMP               52
#define SYS_ACL_NPM_IM_XEDITPTR          56
#define SYS_ACL_NPM_IM_XDATA_PROF_ID     64
#define SYS_ACL_NPM_IM_FLOW_ID_HIGH      48

#define SYS_ACL_UDE_RSV_ID(RSV_TYPE) (0xFFFFFFFF - RSV_TYPE)
#define SYS_WB_APPID(lchip, modid, subid)   (((lchip)<<16) | CTC_WB_APPID(modid, subid))

#define SYS_ACL_ENTRY_HASH_NOT_EXIST(lchip, type, entry_id, pp_bmp)    \
{\
    if (CTC_E_NONE == sys_usw_acl_lookup_entry_hash(lchip, entry_id, type, &pp_bmp)) {return CTC_E_EXIST;}\
}
#define SYS_ACL_ENTRY_HASH_ENTRY_EXIST(lchip, type, entry_id, pp_bmp)    \
{\
    if (CTC_E_NONE != sys_usw_acl_lookup_entry_hash(lchip, entry_id, type, &pp_bmp)) {return CTC_E_NOT_EXIST;}\
}


enum sys_acl_udf_rsv_type
{
    SYS_ACL_UDF_RSV_INVALID= 0,
    SYS_ACL_UDF_RSV_SRV6,
};

typedef enum
{
    SYS_ACL_PP_QUERY_NONE,
    SYS_ACL_PP_QUERY_BITMAP,
    SYS_ACL_PP_QUERY_FIRST_VALID,
    SYS_ACL_PP_QUERY_NUM
}sys_acl_pp_query_type_t;

enum sys_acl_field_key_type_e
{
    SYS_FIELD_KEY_HASH_SEL_ID = 1000,
};

enum sys_acl_hash_key_type
{
    SYS_ACL_HASH_KEY_TYPE_MAC  ,
    SYS_ACL_HASH_KEY_TYPE_IPV4  ,
    SYS_ACL_HASH_KEY_TYPE_L2_L3 ,
    SYS_ACL_HASH_KEY_TYPE_MPLS  ,
    SYS_ACL_HASH_KEY_TYPE_IPV6 ,
    SYS_ACL_HASH_KEY_TYPE_NSH ,
    SYS_ACL_HASH_KEY_TYPE_NUM
};

enum sys_acl_range_type
{
    ACL_RANGE_TYPE_NONE,
    ACL_RANGE_TYPE_PKT_LENGTH  = 1,
    ACL_RANGE_TYPE_L4_SRC_PORT = 2,
    ACL_RANGE_TYPE_L4_DST_PORT = 3,
    ACL_RANGE_TYPE_SVLAN = 4,
    ACL_RANGE_TYPE_CVLAN = 5,
    ACL_RANGE_TYPE_UDF = 6,
    ACL_RANGE_TYPE_SUDF = 7,
    ACL_RANGE_TYPE_NUM
};

enum sys_acl_count_type
{
    ACL_ALLOC_COUNT_TCAM_80,
    ACL_ALLOC_COUNT_TCAM_160,
    ACL_ALLOC_COUNT_TCAM_320,
    ACL_ALLOC_COUNT_TCAM_640,
    ACL_ALLOC_COUNT_HASH,
    ACL_ALLOC_COUNT_NUM
};

typedef enum sys_acl_field_e
{
    SYS_ACL_FIELD_LT_ID = CTC_FIELD_KEY_NUM,
    SYS_ACL_FIELD_LT_ID1,
    SYS_ACL_FIELD_LT_ID2,
    SYS_ACL_FIELD_LT_CLASS,
    SYS_ACL_FIELD_DESTMAP,
    SYS_ACL_FIELD_NH_OFFSET,
    SYS_ACL_FIELD_NH_EXT,
    SYS_ACL_FIELD_DEST_APS,
    SYS_ACL_FIELD_DEST_ECMP,

    SYS_ACL_FIELD_RANGE_CHECK,

    SYS_ACL_FIELD_EXCEPTION_GID,
    SYS_ACL_FIELD_EXCEPTION_FATAL_EXCP_ID,
    SYS_ACL_FIELD_EXCEPTION_EXCP_EN,
    SYS_ACL_FIELD_EXCEPTION_FATAL_EN,

    SYS_ACL_FIELD_UDF1_PROF_ID,
    SYS_ACL_FIELD_UDF1_VALID_BITMAP,
    SYS_ACL_FIELD_UDF2_PROF_ID,
    SYS_ACL_FIELD_UDF2_VALID_BITMAP,
    SYS_ACL_FIELD_IS_NVGRE_PKT,
    SYS_ACL_FIELD_GRE_WITH_KEY,
    SYS_ACL_FIELD_L4_DP_SHARE,
    SYS_ACL_FIELD_L4_SP_SHARE,
    SYS_ACL_FIELD_VN_ID_SHARE,
    SYS_ACL_FIELD_VXLAN_FLAGS_SHARE,
    SYS_ACL_FIELD_Y1731_OAM_LEVEL,
    SYS_ACL_FIELD_Y1731_OAM_OP_CODE,
    SYS_ACL_FIELD_Y1731_OAM_VERSION,
    SYS_ACL_FIELD_GPORT_SHARE,
    SYS_ACL_FIELD_LOGIC_PORT_SHARE,
    SYS_ACL_FIELD_PBM,
    SYS_ACL_FIELD_PORT_BITMAP_MODE0,
    SYS_ACL_FIELD_PORT_BITMAP_MODE1,
    SYS_ACL_FIELD_PORT_BITMAP_MODE2,
    SYS_ACL_FIELD_PORT_BITMAP_MODE3,
    SYS_ACL_FIELD_UDF1_CHUNK0,
    SYS_ACL_FIELD_UDF1_CHUNK1,
    SYS_ACL_FIELD_UDF1_CHUNK2,
    SYS_ACL_FIELD_UDF1_CHUNK3,
    SYS_ACL_FIELD_UDF1_CHUNK4,
    SYS_ACL_FIELD_UDF1_CHUNK5,
    SYS_ACL_FIELD_UDF1_CHUNK6,
    SYS_ACL_FIELD_UDF1_CHUNK7,
    SYS_ACL_FIELD_UDF2_CHUNK0,
    SYS_ACL_FIELD_UDF2_CHUNK1,
    SYS_ACL_FIELD_UDF2_CHUNK2,
    SYS_ACL_FIELD_UDF2_CHUNK3,
    SYS_ACL_FIELD_UDF2_CHUNK4,
    SYS_ACL_FIELD_UDF2_CHUNK5,
    SYS_ACL_FIELD_UDF2_CHUNK6,
    SYS_ACL_FIELD_UDF2_CHUNK7,
    SYS_ACL_FIELD_FLEX_HASH_CHUNK0,
    SYS_ACL_FIELD_FLEX_HASH_CHUNK1,
    SYS_ACL_FIELD_FLEX_HASH_CHUNK2,
    SYS_ACL_FIELD_FLEX_HASH_CHUNK3,
    SYS_ACL_FIELD_FULL_ETHER_TYPE,
    SYS_ACL_FIELD_IPV6_SA_CHUNK0,
    SYS_ACL_FIELD_IPV6_SA_CHUNK1,
    SYS_ACL_FIELD_IPV6_SA_CHUNK2,
    SYS_ACL_FIELD_IPV6_SA_CHUNK3,
    SYS_ACL_FIELD_IPV6_DA_CHUNK0,
    SYS_ACL_FIELD_IPV6_DA_CHUNK1,
    SYS_ACL_FIELD_IPV6_DA_CHUNK2,
    SYS_ACL_FIELD_IPV6_DA_CHUNK3,
    SYS_ACL_FIELD_NSH_CH_CHUNK0,
    SYS_ACL_FIELD_NSH_CH_CHUNK1,
    SYS_ACL_FIELD_NSH_CH_CHUNK2,
    SYS_ACL_FIELD_NSH_CH_CHUNK3,
    SYS_ACL_FIELD_VLAN_XLATE0_HIT,
    SYS_ACL_FIELD_VLAN_XLATE1_HIT,
    SYS_ACL_FIELD_SRH_COMMON_HDR,
    SYS_ACL_FIELD_XDATA_DW0,
    SYS_ACL_FIELD_XDATA_DW1,
    SYS_ACL_FIELD_XDATA_W0,
    SYS_ACL_FIELD_XDATA_W1,
    SYS_ACL_FIELD_XDATA_W2,
    SYS_ACL_FIELD_XDATA_W3,
    SYS_ACL_FIELD_XDATA_B0,
    SYS_ACL_FIELD_XDATA_B1,
    SYS_ACL_FIELD_XDATA_B2,
    SYS_ACL_FIELD_XDATA_B3,
    SYS_ACL_FIELD_STK_XDATA_DW0,
    SYS_ACL_FIELD_STK_XDATA_DW1,
    SYS_ACL_FIELD_STK_XDATA_W0,
    SYS_ACL_FIELD_STK_XDATA_W1,
    SYS_ACL_FIELD_STK_XDATA_B0,
    SYS_ACL_FIELD_STK_XDATA_B1,
    SYS_ACL_FIELD_STK_XDATA_B2,
    SYS_ACL_FIELD_STK_XDATA_B3,
    SYS_ACL_FIELD_STK_HDR_BMP,
    SYS_ACL_FIELD_XD_IM_FLOW_ID,
    SYS_ACL_FIELD_XD_IM_L_FLAG,
    SYS_ACL_FIELD_XD_IM_D_FLAG,
    SYS_ACL_FIELD_XD_IM_SRC_D_FLAG,
    SYS_ACL_FIELD_IPV6_IM_FLOW_ID,
    SYS_ACL_FIELD_IPV6_IM_L_FLAG,
    SYS_ACL_FIELD_IPV6_IM_D_FLAG,
    SYS_ACL_FIELD_INT_TYPE,
    SYS_ACL_FIELD_INT_VER,
    SYS_ACL_FIELD_INT_HOP_ML,
    SYS_ACL_FIELD_INT_REMAIN_HOP_CNT,
    SYS_ACL_FIELD_INT_INSTRUCTION,
    SYS_ACL_FIELD_IS_FRAG,
    SYS_ACL_FIELD_COUNT

} sys_acl_field_t;

typedef struct sys_acl_traverse_data_s
{
    void* data0;
    void* data1;
    void* data2;
    int32 value0;
}sys_acl_traverse_data_t;

typedef struct
{
    uint8  range_id[ACL_RANGE_TYPE_NUM];
    uint32 flag:16;
    uint32 is_program_rg:1;
    uint32 dir:1;
    uint32 malloced:1;
    uint32 rsv:13;
    uint16 range_bitmap;
    uint16 range_bitmap_mask;
}sys_acl_range_info_t;

struct sys_acl_udf_info_s
{
    uint8 is_sudf;
    uint8 udf_offset_num;
    uint16 key_index;
    uint16 udf_hit_index;
    uint8  key_index_used;
    uint8  scl_offset_num;
    uint8  granularity;
};
typedef struct sys_acl_udf_info_s   sys_acl_udf_info_t;

typedef struct
{
    ctc_direction_t dir;
    uint8           type;

    uint8           block_id;      /* means acl priority, for hash is 0xFF. */
    uint8           bitmap_status;
    uint8          lchip ; /*only used for bitmap*/

    union
    {
        ctc_port_bitmap_t port_bitmap;
        uint16            port_class_id;
        uint16            vlan_class_id;
        uint16            l3if_class_id;
        uint16            service_id;
        uint8             pbr_class_id;
        uint16            gport;
    } un;
    uint8            key_size;
}sys_acl_group_info_t;

typedef struct
{
    ctc_slistnode_t head;
    uint32               group_id; /* keep group_id top! */
    uint32               entry_count;
    uint8                lchip;
    uint8                flag;              /*refer to SYS_ACL_GROUP_FLAG_XXX*/
    uint16               aset_id      : 12,          /* 0/254/255 for default */
                         rsv          : 4;
    ctc_list_pointer_t   entry_list;      /* a list that link entries belong to this group */
    sys_acl_group_info_t group_info;        /* group info */
}sys_acl_group_t;

#define SYS_ACL_LEAGUE_CONFIG_INIT        0
#define SYS_ACL_LEAGUE_CONFIG_SET         1
#define SYS_ACL_LEAGUE_CONFIG_UNSET       2
#define SYS_ACL_LEAGUE_CONFIG_EXPAND      3
#define SYS_ACL_LEAGUE_CONFIG_COMPRESS    4
#define SYS_ACL_LEAGUE_CONFIG_NPM_IM     5
#define SYS_ACL_LEAGUE_CONFIG_FID         6
#define SYS_ACL_LEAGUE_CONFIG_CANCEL      7

struct sys_acl_league_glb_config_s
{
    uint8  block_id;
    uint8  op_type;     /*ref to SYS_ACL_LEAGUE_CONFIG_XXX*/
    uint8  old_part_num;
    uint32 npm_im_en:1;
    uint32 fid_en:1;
    uint32 cancel_sub_blk_cnt:5;
    uint32 global_pp_en:1;
    uint32 rsv:24;
    uint8* sub_blk_list;
};
typedef struct sys_acl_league_glb_config_s sys_acl_league_glb_config_t;

extern char *ifp_field_str[];

extern int32
sys_usw_acl_init(uint8 lchip, ctc_acl_global_cfg_t* acl_global_cfg);
extern int32
sys_usw_acl_deinit(uint8 lchip);
extern int32
sys_usw_acl_init_done(uint8 lchip);
extern int32
sys_usw_acl_set_flex_key_fields(uint8 lchip, ctc_acl_flex_key_t* acl_flex_key);
extern int32
sys_usw_acl_get_flex_key_fields(uint8 lchip, ctc_acl_flex_key_t* acl_flex_key);
extern int32
sys_usw_acl_create_presel(uint8 lchip, ctc_acl_presel_t* acl_presel);
extern int32
sys_usw_acl_destroy_presel(uint8 lchip, uint16 presel_id);
extern int32
sys_usw_acl_add_presel_fields(uint8 lchip, uint16 presel_id, uint8 fields_cnt, ctc_field_key_t *fields);
extern int32
sys_usw_acl_remove_presel_fields(uint8 lchip, uint16 presel_id, uint8 fields_cnt, ctc_field_key_t *fields);

extern int32
sys_usw_acl_create_group(uint8 lchip, uint32 group_id, ctc_acl_group_info_t* group_info);
extern int32
sys_usw_acl_destroy_group(uint8 lchip, uint32 group_id);
extern int32
sys_usw_acl_install_group(uint8 lchip, uint32 group_id, ctc_acl_group_info_t* group_info);
extern int32
sys_usw_acl_uninstall_group(uint8 lchip, uint32 group_id);
extern int32
sys_usw_acl_get_group_info(uint8 lchip, uint32 group_id, ctc_acl_group_info_t* group_info);
extern int32
sys_usw_acl_add_entry(uint8 lchip, uint32 group_id, ctc_acl_entry_t* acl_entry);
extern int32
sys_usw_acl_remove_entry(uint8 lchip, uint32 entry_id);
extern int32
sys_usw_acl_install_entry(uint8 lchip, uint32 entry_id);
extern int32
sys_usw_acl_uninstall_entry(uint8 lchip, uint32 entry_id);
extern int32
sys_usw_acl_remove_all_entry(uint8 lchip, uint32 group_id);
extern int32
sys_usw_acl_set_entry_priority(uint8 lchip, uint32 entry_id, uint32 priority);
extern int32
sys_usw_acl_get_multi_entry(uint8 lchip, ctc_acl_query_t* query);
extern int32
sys_usw_acl_copy_entry(uint8 lchip, ctc_acl_copy_entry_t* copy_entry);
extern int32
sys_usw_acl_set_hash_field_sel(uint8 lchip, ctc_acl_hash_field_sel_t* field_sel);
extern int32
sys_usw_acl_get_hash_field_sel(uint8 lchip, uint8 hash_key_type, uint8 field_sel_id, uint16 key_field_type, uint8* value_out);
extern int32
sys_usw_acl_add_key_field(uint8 lchip, uint32 entry_id, ctc_field_key_t* key_field);
extern int32
sys_usw_acl_remove_key_field(uint8 lchip, uint32 entry_id, ctc_field_key_t* key_field);
extern int32
sys_usw_acl_add_action_field(uint8 lchip, uint32 entry_id, ctc_acl_field_action_t* action_field);
extern int32
sys_usw_acl_remove_action_field(uint8 lchip, uint32 entry_id, ctc_acl_field_action_t* action_field);
extern int32
sys_usw_acl_set_field_to_hash_field_sel(uint8 lchip, uint8 key_type, uint8 field_sel_id, ctc_field_key_t* sel_field);
extern int32
sys_usw_acl_add_cid_pair(uint8 lchip, ctc_acl_cid_pair_t* cid_pair);
extern int32
sys_usw_acl_remove_cid_pair(uint8 lchip, ctc_acl_cid_pair_t* cid_pair);
extern int32
sys_usw_acl_show_status(uint8 lchip);
extern int32
sys_usw_acl_show_entry(uint8 lchip, uint8 type, uint32 param, uint16 key_type, uint8 detail, ctc_field_key_t* p_grep, uint8 grep_cnt, uint8 show_inner);
extern int32
sys_usw_acl_show_group(uint8 lchip, uint8 type);
extern int32
sys_usw_acl_map_ctc_to_sys_hash_key_type(uint8 key_type ,uint8 *o_key_type);
extern int32
sys_usw_acl_get_udf_entry(uint8 lchip,  ctc_acl_classify_udf_t* udf_entry);
extern int32
sys_usw_acl_get_udf_hit_index(uint8 lchip,  uint32 udf_id, uint16* udf_hit_index);
extern int32
sys_usw_acl_resv_udf_for_srv6(uint8 lchip, uint32* udf_index_base, uint8 sid_format, uint8 usid_prefix_len, uint8 gsid_prefix_len, uint8 is_deinit);
extern int32
sys_usw_acl_add_udf_entry(uint8 lchip,  ctc_acl_classify_udf_t* udf_entry);
extern int32
sys_usw_acl_get_udf_id(uint8 lchip, uint16 udf_hit_index, uint32* p_udf_id);
int32
sys_usw_acl_get_udf_key_index(uint8 lchip,  uint32 udf_id, uint32* index);
extern int32
sys_usw_acl_remove_udf_entry(uint8 lchip,  ctc_acl_classify_udf_t* udf_entry);
extern int32
sys_usw_acl_add_udf_entry_key_field(uint8 lchip,  uint32 udf_id, ctc_field_key_t* key_field);
extern int32
sys_usw_acl_remove_udf_entry_key_field(uint8 lchip, uint32 udf_id, ctc_field_key_t* key_field);
extern int32
sys_usw_acl_check_udf_ad_id_mode(uint8 lchip, ctc_acl_classify_udf_t* udf_entry);
extern int32
sys_usw_acl_count_udf_entry(uint8 lchip, ctc_acl_classify_udf_t* udf_entry, uint8 is_add);
extern int32
sys_usw_acl_set_league_mode(uint8 lchip, ctc_acl_league_t* league);
extern int32
sys_usw_acl_get_league_mode(uint8 lchip, ctc_acl_league_t* league);
extern int32
sys_usw_acl_reorder_entry(uint8 lchip, ctc_acl_reorder_t* reorder);
extern int32
sys_usw_acl_reorder_stats(uint8 lchip, ctc_acl_reorder_t* p_reorder, uint32* fail_list, uint32* fail_cnt);
extern int32
sys_usw_acl_set_dot1ae_crypt_error_to_cpu_en(uint8 lchip, uint8 enable);
extern int32
sys_usw_acl_set_wlan_crypt_error_to_cpu_en(uint8 lchip, uint8 enable);
extern int32
sys_usw_acl_get_udf_info(uint8 lchip,  uint32 udf_id, sys_acl_udf_info_t* p_udf_info);
extern int32 
sys_usw_acl_get_udf_info_by_ad_id(uint8 lchip, uint32 udf_ad_id, sys_acl_udf_info_t* p_udf_info);
extern int32
sys_usw_acl_get_flow_udf_id_by_adindex(uint8 lchip, uint16 ad_index, uint32* udf_id);
extern int32
sys_usw_acl_add_port_field(uint8 lchip, uint32 entry_id, ctc_field_port_t port, ctc_field_port_t port_mask);
extern int32
sys_usw_acl_get_resource_by_priority(uint8 lchip, uint8 priority, uint8 dir, uint32*total, uint32* used);
extern int32
sys_usw_acl_add_remove_field_list(uint8 lchip, uint32 entry_id, void* p_field_list, uint32* p_field_cnt, uint8 is_key, uint8 is_add);
extern int32
sys_usw_acl_build_field_range(uint8 lchip, uint8 dir, uint8 range_type, uint16 min, uint16 max, uint16* p_range_bitmap, uint8 is_add);
extern int32
sys_usw_acl_get_upa_en(uint8 lchip, uint8 dir, uint8* p_enable);
extern uint32
sys_usw_acl_get_lkup_level_bmp(uint8 lchip, uint8 dir, uint8 block_id);
extern int32
sys_usw_acl_replace_block(uint8 lchip, ctc_acl_replace_t* p_replace);
extern int32
sys_usw_acl_set_group_info(uint8 lchip, uint32 group_id, ctc_acl_group_info_t* group_info);
extern int32
sys_usw_acl_set_action_priority(uint8 lchip, uint8 block_id, uint8 action_pri);
extern int32
sys_usw_acl_get_action_priority(uint8 lchip, uint8 block_id, uint8* p_action_pri);
extern int32
sys_usw_acl_map_l4_type_to_ip_protocol(uint8 lchip, uint8 l3_type, uint8 l4_type, uint32* o_ip_protocol, uint32* o_mask);
extern int32
sys_usw_acl_map_ip_protocol_to_l4_type(uint8 lchip, uint8 l3_type, uint8 ip_protocol,uint32* o_l4_type, uint32* o_mask);
extern char*
sys_usw_acl_output_udf(uint8 * in_data);
extern int32
sys_usw_acl_lookup_entry_hash(uint8 lchip, uint32 entry_id, uint8 type, uint16* pp_bmp);
extern int32
sys_usw_acl_add_entry_hash(uint8 lchip, uint32 entry_id, uint16 pp_bmp, uint8 type);
extern int32
sys_usw_acl_remove_entry_hash(uint8 lchip, uint32 entry_id, uint8 type);

extern int32
sys_usw_acl_set_aset_fields(uint8 lchip, ctc_acl_aset_t* ctc_aset);
extern int32
sys_usw_acl_get_aset_fields(uint8 lchip, ctc_acl_aset_t* ctc_aset);

extern int32 
sys_usw_acl_get_pp_en_lkup_property(uint8 lchip, uint8 dir, uint8 priority, uint8 *global_pp_en);
extern int32 
sys_usw_acl_check_league_block_valid(uint8 lchip, ctc_acl_league_t* league, uint32 global_lkup_bitmap);
extern int32 
sys_usw_acl_get_sys_group_info_by_gid(uint8 lchip, uint32 group_id, ctc_direction_t *dir, uint8 *priority);
extern int32 
sys_usw_acl_get_sys_group_info_by_eid(uint8 lchip, uint32 entry_id, ctc_direction_t *dir, uint8 *priority);
extern uint32 
sys_usw_acl_get_lkup_pp_en_bmp(uint8 lchip, uint8 dir);
extern int32 
sys_usw_acl_set_ifa_ver(uint8 lchip, uint8 ifa_ver);

#ifdef __cplusplus
}
#endif
#endif
